<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');
class Archive_control extends CI_Controller {

	function __construct()
	{
		parent::__construct();
		$this->load->helper(array('form', 'url'));
		$this->load->library(array('form_validation','session'));
		$this->load->model('download_model');
	}

	function index()
	{	
		$data['years'] = $this->download_model->get_years();
		$this->load->view('archive1', $data);
	}


	function show_year($year)
	{
		$data['missions'] = $this->download_model->get_missions($year);
		$data['year'] = $year;
		$this->load->model('projekt_model');
		$value = $this->projekt_model->show_table($year);
		$data['tabulka'] = $value;
		$this->load->view('archive2', $data);
	}
}
